
using Volo.Abp.Modularity.PlugIns;

namespace AbpVnext_Module
{
    public class Program
    {
        public static void Main(string[] args)
        {
            var builder = WebApplication.CreateBuilder(args);
            //清除日志工厂
            builder.Logging.ClearProviders();
            //使用Abp模块，配置service
            builder.Services.AddApplication<ProjectModule>(option =>
            {
                //加载插件，主项目动态扩展功能
                option.PlugInSources.AddFolder("D:\\学习\\项目\\Plugins");
            });
            ////builder.Services.AddApplication<ProjectModule>(option =>
            ////{
            ////    //加载插件，主项目动态扩展功能
            ////    option.PlugInSources.AddFolder("E:\\项目\\ABP\\Plugins");
            ////});
            //使用aufofac中间件
            builder.Host.UseAutofac();
            var app = builder.Build();
            //使用abp模块，配置中间件
            app.InitializeApplication();
            app.Run();
        }
    }
}
